package com.fc.authentication.modules.product.service;

import com.fc.authentication.modules.product.domain.Product;
import com.fc.authentication.modules.product.repository.ProductRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;

/**
 * Created by Sunny on 2018/6/29.
 */
@Service
public class ProductService {

    @Autowired
    private ProductRepository productRepository;

    public Page<Product> findAllProducts(Pageable pageable)
    {
        return productRepository.findAll(pageable);
    }
}
